package com.gdupt.service.impl;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.gdupt.entity.ServiceManagement;
import com.gdupt.mapper.ServiceManagementMapper;
import com.gdupt.service.IServiceManagementService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 服务管理 服务管理 服务实现类
 * </p>
 *
 * @author gdupt
 * @since 2018-11-21
 */
@Service
public class ServiceManagementServiceImpl extends ServiceImpl<ServiceManagementMapper, ServiceManagement> implements IServiceManagementService {

    @Autowired
    private  ServiceManagementMapper serviceManagementMapper;
    boolean flg =false;
    @Override
    public boolean insertService(ServiceManagement serviceManagement) {
       flg = serviceManagementMapper.insertService(serviceManagement);
        return flg;
    }

    @Override
    public List<ServiceManagement> findNewService(IPage page,String customerName, String outline,String serviceType) {
        List<ServiceManagement> list = serviceManagementMapper.findNewService(page,customerName,outline,serviceType);
        return list;
    }

    @Override
    public boolean updateStatus(Map map) {
       flg= serviceManagementMapper.updateStatus(map);
        return flg;
    }
}
